﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ucListDoiTac.ascx.cs" Inherits="PureLink.AdminCP.PageUC.ucListDoiTac" %>
<h2 style="text-align: left;">
    Danh sách Đối tác</h2>
<table style="border: 0px;" width="100%">
    <tr>
        <td>
            <asp:GridView ID="gvDT" runat="server" AutoGenerateColumns="False" BackColor="White"
                BorderColor="#CC9966" BorderStyle="Solid" BorderWidth="1px" 
                CellPadding="4" Width="100%"
                DataKeyNames="DoiTacID" OnPageIndexChanging="gvDT_PageIndexChanging" OnRowDeleting="gvDT_RowDeleting"
                OnSelectedIndexChanged="gvDT_SelectedIndexChanged"
                AllowPaging="True" PageSize="50">
                <RowStyle BackColor="White" ForeColor="#330099" HorizontalAlign="Center" />
                <Columns>
                    <asp:TemplateField HeaderText="STT" HeaderStyle-Width="10%">
                        <ItemTemplate>
                            <%# Container.DataItemIndex + 1 %>
                        </ItemTemplate>
                        <ItemStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:BoundField DataField="TenDoiTac" HeaderText="Tên ĐT" >
                        <ItemStyle HorizontalAlign="Left" />
                    </asp:BoundField>
                    <asp:TemplateField HeaderText="Logo" HeaderStyle-Width="20%">
                        <ItemTemplate>
                            <asp:Image ID="imgVideo" ImageUrl='<%#"~/Media/" + Eval("ImageURL") %>' runat="server" Width="100px" Height="60px" />
                        </ItemTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField HeaderText="Action" HeaderStyle-Width="10%" ItemStyle-HorizontalAlign="Center">
                        <ItemTemplate>
                            <asp:ImageButton ID="btEdit" runat="server" CommandName="Select" CommandArgument='<%#Eval("DoiTacID") %>' ImageUrl="~/AdminCP/images/edit_16x16.gif" />
                            <asp:ImageButton ID="btDelete" runat="server" CommandArgument='<%#Eval("DoiTacID") %>'
                                CommandName="Delete" ImageUrl="~/AdminCP/images/delete_16x16.gif" OnClientClick="return confirm('Có muốn xóa bản ghi này? Nhấn OK để xóa!')" />
                            <%--<asp:Button ID="btnChiTiet" runat="server" CommandName="chitiet" CommandArgument='<%#Eval("AlbumID") %>' Text="Chi tiết" />--%>
                            <asp:LinkButton ID="btnChiTiet" Visible="false" runat="server" CommandName="chitiet" CommandArgument='<%#Eval("DoiTacID") %>' Text="Chi tiết"></asp:LinkButton>
                        </ItemTemplate>
                    </asp:TemplateField>
                </Columns>
                <FooterStyle BackColor="#FFFFCC" ForeColor="#330099" />
                <PagerStyle BackColor="#FFFFCC" ForeColor="#330099" HorizontalAlign="Center" />
                <SelectedRowStyle BackColor="#FFCC66" Font-Bold="True" ForeColor="#663399" />
                <HeaderStyle BackColor="#990000" Font-Bold="True" ForeColor="#FFFFCC" />
            </asp:GridView>
        </td>
    </tr>
</table>
<asp:Button ID="btnAdd" runat="server" Text="Thêm mới" onclick="btnAdd_Click" />